<?php $this->load->view('home/layout/header') ?>
<header class="my-head flex">
	<div class="my-return">
		<a href="<?php echo site_url('home/refund/sceneryRefundList'); ?>">
			<i class="iconfont icon-zuojiantou"></i>
		</a>
	</div>
	<div class="add-name">
		订单详情
	</div>
	<div class="pay-option flex">
		<a href="<?php echo site_url(); ?>">
			<i class="iconfont">&#xe634;</i>
		</a>
		<a href="tel:400-0571-648">
			<i class="iconfont pay-phone">&#xe635;</i>
		</a>
	</div>
</header>
<section class="detail-text widthMax">
	<div class="detail-head">
		<h6>
			申请时间：<?php echo $editDetail->created_at; ?>
		</h6>
		<div class="detail-label">
			<div class="tion-state flex">
				<h4 class="flex-1">
					<?php switch ($editDetail->flag) {
						case 1:
							echo '退票中';
							break;
						case 2:
							echo '已退票';
							break;
						case 4:
							echo '退票失败';
							break;
						default:
							break;
					} ?>
				</h4>
				<div class="tion-price">
					退票金额：<i><span>￥</span><?php echo $editDetail->amount_back; ?></i>
				</div>
			</div>
			<?php $price = bcdiv($editDetail->o_amount_fee, $editDetail->o_num, 2);//单价 ?>
			<div class="tion-pave flex">
				<p class="flex-1">订单号：<?php echo $orderInfo->order_id; ?></p>
				<div>退款明细：￥<?php echo $price , 'x' , ($editDetail->o_num - $editDetail->n_num); ?></div>
			</div>
			<?php if ( $editDetail->poundage > 0 ) : ?>
			<div class="tion-pave flex">
				<div class="flex-1"></div>
				<div>手续费：￥<?php echo  bcsub($editDetail->o_amount_fee, bcadd($editDetail->n_amount_fee, $editDetail->amount_back, 2), 2); ?></div>
			</div>
			<?php endif; ?>
		</div>
	</div>
	<div class="break-tion">
		<h6>
			下单时间：<?php echo date('Y-m-d H:i:s', $orderInfo->ordertime); ?>
		</h6>
		<dl class="tion-dl">
			<dt>
				<div class="flex">
					<h4 class="flex-1"><?php echo $orderInfo->goods_name; ?></h4>
					<div class="break-Price">订单金额：<i><span>￥</span><?php echo $editDetail->o_amount_fee; ?></i></div>
				</div>
				<p>出行时间：<?php echo date('Y-m-d', $orderInfo->plantime); ?></p>
			</dt>
			<dd>
				<h5>购买份数：</h5>
				<p class="flex-1">￥<?php echo $price , 'x' , $editDetail->o_num , '份'; ?></p>
			</dd>
			<dd>
				<h5>剩余份数：</h5>
				<p class="flex-1">￥<?php echo $price , 'x' , $editDetail->n_num , '份'; ?></p>
			</dd>
		</dl>
		<ul class="tion-ul">
			<li>
				<h5>取票人：</h5>
				<p class="flex-1"><?php echo $orderInfo->play_name; ?></p>
			</li>
			<li>
				<h5>身份证：</h5>
				<p class="flex-1"><?php echo substr_sfz($orderInfo->sfz); ?></p>
			</li>
			<li>
				<h5>联系电话：</h5>
				<p class="flex-1"><?php echo subStrMobilePhone($orderInfo->phone); ?></p>
			</li>
		</ul>
	</div>
	<?php if ( $editDetail->flag ==4 && empty($editDetail->note) ) : ?>
	<div class="break-foot">
		备注：<?php echo $editDetail->note; ?>
	</div>
	<?php endif; ?>
</section>
<?php $this->load->view('home/layout/footer'); ?>